# the minimum version of CMake.
cmake_minimum_required(VERSION 3.5.0)
project(LinphoneApplication)

set(NATIVERENDER_ROOT_PATH ${CMAKE_CURRENT_SOURCE_DIR})

if(DEFINED PACKAGE_FIND_FILE)
    include(${PACKAGE_FIND_FILE})
endif()

include_directories(${NATIVERENDER_ROOT_PATH}
                    ${NATIVERENDER_ROOT_PATH}/include)

add_library(entry SHARED napi_init.cpp log/ohos_log.cpp)
target_link_libraries(entry PUBLIC libace_napi.z.so hilog_ndk.z)
target_include_directories(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/include)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/liblinphone.so.10)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libspeex.so.6)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libspeexdsp.so.6)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libmediastreamer2.so)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libortp.so.15)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/liblinphone++.so.10)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libbctoolbox.so.1)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libbelcard.so.1)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libbelle-sip.so.1)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libbelr.so.1)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libbv16.so)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libbzrtp.so.0)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libdecaf.so.0)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libgsm.so)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libjsoncpp.so.25)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/liblime.so.0)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libmbedtls.so.21)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libmbedcrypto.so.16)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libmbedx509.so.7)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libopus.so.0)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libortp.so.15)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libsoci_core.so.4.0)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libsoci_sqlite3.so.4.0)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libsqlite3.so)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libsrtp2.so.2.7.0)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libxerces-c.so)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libxml2.so.2)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libmswebrtc.so)
target_link_libraries(entry PUBLIC ${NATIVERENDER_ROOT_PATH}/thirdparty/linphone/lib/libz.so.1)
